package com.rrf.securityjwt.controller;

import com.rrf.securityjwt.util.OkhttpUtil;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.io.IOException;

/**
 * @Author:aha
 * @Description:测试啦啦啦哈哈哈哈
 * @Date: 2018/8/9 16:19
 * @Modified By:
 */
@RestController
@RequestMapping("/hello")
public class HelloController {

    @GetMapping("/getNews")
    public String getNews(){
        String news = OkhttpUtil.get("https://www.apiopen.top/journalismApi",null);
        return news;
    }

    @GetMapping("/hello")
    public String hello(){
        return "请求成功";
    }
}
